home *** CD-ROM | disk | FTP | other *** search
/ CD Actual 22 / PC Actual CD 22.iso / SHARE / prog / POVRAY / E-P-O.ZIP / SCREEN.INC < prev    next >
Encoding:
Text File  |  1996-10-31  |  2.2 KB  |  69 lines

  1.  
  2. //------------------------------------------------------------------->
  3. //
  4. // screen.inc
  5. //
  6. // "Easy POV Oven"
  7. //
  8. // Written By: Paul T. Dawson
  9. //             ptdawson@voicenet.com
  10. //             http://www.voicenet.com/~ptdawson
  11. //
  12. // All code and techniques are PUBLIC DOMAIN - have fun with it!
  13. //
  14. //------------------------------------------------------------------->
  15. //
  16. // This file builds the "Screen" object.
  17. //
  18. //------------------------------------------------------------------->
  19. //
  20. // Build it!
  21.  
  22.         #declare Screen = union {
  23.  
  24.         // Actual picture on screen.
  25.                 box { < 0, 0, 0 > < 1, 1, 0.1 >
  26.                         pigment {
  27.                         image_map { tga "test-1.tga" interpolate 2 } }
  28.                         scale < 16, 12, 1 >
  29.                         rotate x * 15
  30.                         } // End of box.
  31.  
  32.         // Black box around that.
  33.                 box { < -1, -1, 0.1 > < 17, 13, 1.5 >
  34.                         pigment { Gray20 }
  35.                         normal { crackle 0.2 scale 0.05 }
  36.                         rotate x * 15
  37.                         } // End of box.
  38.  
  39.         // Little red lights at bottom of screen.
  40.                 sphere { < 10, -0.5, 0.1 >, 0.2 pigment { Red } rotate x * 15 }
  41.                 sphere { < 12, -0.5, 0.1 >, 0.2 pigment { Red } rotate x * 15 }
  42.                 sphere { < 14, -0.5, 0.1 >, 0.2 pigment { Red } rotate x * 15 }
  43.  
  44.         // Bottom part.
  45.                 box { < -1, -1, 0 > < 17, -3, -12 >
  46.                         pigment { Gray20 }
  47.                         normal { crackle 0.2 scale 0.05 }
  48.                         } // End of box.
  49.  
  50.         // Goofy keys.
  51.                 #declare X = 0 #while ( X <= 15 )
  52.                 #declare Z = -9 #while ( Z <= -2 )
  53.  
  54.                         box { < X, -1, Z > < X+1, -0.5, Z+1 >
  55.                                 pigment { White } }
  56.  
  57.                 #declare Z = Z + 1.5 #end
  58.                 #declare X = X + 1.5 #end
  59.  
  60.         // Move it all up so bottom is on y=0.
  61.                 translate y*3
  62.  
  63.         } // End of union.
  64.  
  65. //------------------------------------------------------------------->
  66. //
  67. // End of this file.
  68.  
  69.